SimpleCalendar 2.2 - by uziq - May 10 2005

This plugin creates a calendar.  It can be used with the SimpleEvents script, to add reminders and highlight days.


v2.2 - The events will auto update after you manually edit Events.dat.



------------------------------------------------------------------------

UNZIPPING:
You can unzip directly to your Samurize directory, and all the files will go into their correct folders.
	SimpleCalendar.dll and SimpleCalendar_MonthChanger.exe go in the plugins folder.
	SimpleCalendar.ini and Modernize.ini goes in the configs folder.
	SimpleEvents.vbs goes in the Samurize scripts folder.
	Events.dat goes in Samurize\Scripts\SimpleEvents\

------------------------------------------------------------------------

BASIC INSTRUCTIONS:
The provided configs have some different examples of possible calendars.  The easiest thing to do is just to copy a calendar and paste it into your own config.  But in general, a basic six-row calendar needs 10 separate meters:
	DisplayMonthName
	DisplayWeekday (seven of them)
	DisplayDays_InThisMonth
	DisplayDays_Today
There's additional functions that you can also use.  Read down below for an explanation of each function and the parameters that they use.

------------------------------------------------------------------------

IMPORTANT NOTE ABOUT SIMPLEEVENTS:
SimpleEvents is an optional add-on script that let's you enter reminders for days on the calendar.
Due to a tab-alignment issue, the number highlights from SimpleEvents 1.0 are *NOT* compatible with SimpleCalendar 2.0 or greater.  So you'll need to use SimpleEvents 1.5 instead.
The highlights for the days are stored in a single text file.  Here's the highlighting options, along with where they are located in the file:
	Day Numbers	ReadLine - 1 : Number of Lines - 6
	Underline __	ReadLine - 7 : Number of Lines - 6
	Parenthesis (  )	ReadLine - 13 : Number of Lines - 6
	Brackets [  ]	ReadLine - 19 : Number of Lines - 6
	Hollow Squares - c	ReadLine - 26 : Number of Lines - 6
	Filled Squares - g	ReadLine - 31 : Number of Lines - 6
	Hollow Circle - O	ReadLine - 37 : Number of Lines - 6
	Filled Circle - n	ReadLine - 43 : Number of Lines - 6
	Asterisk *		ReadLine - 49 : Number of Lines - 6
	Hollow Rounded Rect 5	ReadLine - 55 : Number of Lines - 6
	Upper-left Triangles z	ReadLine - 61 : Number of Lines - 6
There are some variables in the script that you can edit by opening SimpleEvents.vbs in a text editor.
See the provided SimpleEvents config for some examples.

------------------------------------------------------------------------

ABOUT MONTHSHIFT:
Nearly all the functions have a parameter called MonthShift.  This lets you display as many months as you'd like.  If you plan on having only one month in your config, then MonthShift should always be 0.  Otherwise, use a number relative to the current month. (MonthShift=1 is next month, MonthShift=2 is two months from now, etc; You can also use negative numbers to show previous months).

------------------------------------------------------------------------

FUNCTIONS:
 DisplayYear (the year)
	* This function will return an alert value of %b for the current year, which is optional to use.  The alert is useful for tracking the current year when multiple years are displayed.  To use the alert, check "Enable Alert-Value" and choose alert when value contains %b
	 UseTwoDigits = 0  (use four digits)
	 UseTwoDigits = 1  (use two digits)

 DisplayMonthName (the month name)
	* This function will return an alert value of %b for the current month, which is optional to use.  The alert is useful for tracking the current month when multiple months are displayed.  To use the alert, check "Enable Alert-Value" and choose alert when value contains %b
	 Abbreviate = 0  (do not abbreviate)
	 Abbreviate = 1  (do abbreviate)
	 Format = 0  (use default spelling)
	 Format = 1  (capitalize the first letter)
	 Format = 2  (capitalize all the letters)

 DisplayDays_Today (a month layout with only the current day)

 DisplayDays_InThisMonth (a month layout with all the days in the month)
	 OmitToday = 0  (do not remove today)
	 OmitToday = 1  (do remove today)

 DisplayDays_InSurrounding (a month layout with the surrounding days from the previous and next months)

 DisplayDays_MarkOutPrevious (a month layout overlay with marked out previous days)
	 MarkOutString = any one or two characters used to mark out previous days
	 IncludePreviousMonth = 0  (do not mark out days from the previous month)
	 IncludePreviousMonth = 1  (do mark out days from the previous month)

 DisplayWeekdays1 - 7 (a weekday, depending on the position)
	Weekday positions from left to right:  1-2-3-4-5-6-7
	* These functions will return an alert value of %b for the current weekday, which is optional to use.  The alert is useful for tracking the current weekday when multiple months are displayed.  To use the alert, check "Enable Alert-Value" and choose alert when value contains %b
	Then you can choose a different font/color, etc, to make the weekday stand out.
	 Abbreviate = 0  (do not abbreviate)
	 Abbreviate = 1  (do abbreviate)
	 Length = 0  (full weekday name, or full abbreviated name)
	 Length = 1  (first letter only)
	 Length = 2  (first two letters)
	 Length = 3  (first three letters)
	 Format = 0  (use default spelling)
	 Format = 1  (capitalize the first letter)
	 Format = 2  (capitalize all the letters)

 DisplayWeekNumbers_Today (a weeknumber layout with only the current weeknumber)

 DisplayWeekNumbers_InThisMonth (a weeknumber layout with weeknumbers from the current month)
	 OmitToday = 0  (do not remove the current weeknumber)
	 OmitToday = 1  (do remove the current weeknumber)

 DisplayWeekNumbers_InSurrounding (a weeknumber layout with weeknumbers from the surrounding month)



---------- INDICATOR STYLES ----------
Indicator Styles help to improve the look of the calendar.  You can use as many of them as you want.

 S1_Underline_Today - __
 S2_Parenthesis_Today - (  )
 S3_Brackets_Today - [  ]
 S4_Asterisk_Today - *  (use Webdings to make a filled asterisk for the current day)
 S5_HollowRoundedRect_Today - 5  (use Wingdings 2 to make a hollow rounded rectangle for the current day)
 S5_HollowRoundedRects_InCurrentMonth - 5  (use Wingdings 2 to make hollow rounded rectangles for all the days in the month)
	 OmitToday = 0  (do not remove the current day)
	 OmitToday = 1  (do remove the current day)
 S5_HollowRoundedRects_InSurrounding - 5  (use Wingdings 2 to make hollow rounded rectangles for all the days in the surrounding months)
 S6_HollowSquare_Today - c  (use Webdings to make a hollow square for the current day)
 S6_HollowSquares_InThisMonth - c  (use Webdings to make a hollow square for all the days in the month)
	 OmitToday = 0  (do not remove the current day)
	 OmitToday = 1  (do remove the current day)
 S6_HollowSquares_InSurrounding - c  (use Webdings to make a hollow square for all the days in the surrounding months)
 S7_FilledSquare_Today - g  (use Webdings to make a filled square for the current day)
 S7_FilledSquares_InThisMonth - g  (use Webdings to make a filled square for all the days in the month)
	 OmitToday = 0  (do not remove the current day)
	 OmitToday = 1  (do remove the current day)
 S7_FilledSquares_InSurrounding - g  (use Webdings to make a filled square for all the days in the surrounding months)
 S8_HollowCircle_Today - O  (use Arial 16 or something similar to make a hollow circle for the current day)
 S8_HollowCircles_InThisMonth - O  (use Arial to make a hollow circle for all the days in the month)
	 OmitToday = 0  (do not remove the current day)
	 OmitToday = 1  (do remove the current day)
 S8_HollowCircles_InSurrounding - O  (use Arial to make a hollow circle for all the days in the surrounding months)
 S9_FilledCircle_Today - n  (use Webdings to make a filled circle for the current day)
 S9_FilledCircles_InThisMonth - n  (use Webdings to make a filled circle for all the days in the month)
	 OmitToday = 0  (do not remove the current day)
	 OmitToday = 1  (do remove the current day)
 S9_FilledCircles_InSurrounding - n  (use Arial to make a filled circle for all the days in the surrounding months)
 S100_UserDefined_Today (specify whatever you'd like to use for today)
	 IndicatorStr = any string between 1 and 4 characters long
 S100_UserDefined_InThisMonth (specify whatever you'd like to use for days in the month)
	 IndicatorStr = any string between 1 and 4 characters long
	 OmitToday = 0  (do not remove the current day)
	 OmitToday = 1  (do remove the current day)
 S100_UserDefined_InSurrounding (specify whatever you'd like to use for days in the surrounding months)
	 IndicatorStr = any string between 1 and 4 characters long


---------- LINKS ----------
NOTE: These link functions must have "Allow Meter-Linkage" checked.  The links will automatically be filled in whenever the config is ran, but they will not be visible in the editor.

 Link_CurrentDate (go to the current date)
 Link_NextMonth (go to the next month)
 Link_NextYear (go to the next year)
 Link_PreviousMonth (go to the previous month)
 Link_PreviousYear (go to the previous year)
 Link_SimpleEvents_GridPosition (useful for grid calendars; returns a link for SimpleEvents, based on the position in the calendar)
	 Position = 1-42  (the position on the calendar from the top-left to the bottom-right)
	* You need to use 42 separate instances of this function (actually, only 37 are required, but 42 let's you click days in the next month).
	Here's the grid positions on the calendar:
	01-02-03-04-05-06-07
	08-09-10-11-12-13-14
	15-16-17-18-19-20-21
	22-23-24-25-26-27-28
	29-30-31-32-33-34-35
	36-37-38-39-40-41-42
	TIP: When you make the separate squares for links, it's a good idea to make a single row and column first to make sure they're going to line up with the day numbers.  Then, copy and paste the rest of the boxes, while specifying a different position for each one.  You can also select all the meters at once and resize them by holding Shift and using the arrow keys.
 Link_SimpleEvents_DayNumber (useful for long calendars; returns a link for SimpleEvents, based on the day number)
	 Position = 1-31  (the day number)
	* You need to use 31 separate instances of this function.


---------- LONG CALENDARS ----------
 Horizontal_Days_Today (a horizontal layout of the current day)
	 DaysBehind = 0  (start at the first day of the month)
	 DaysBehind > 0  (start a specific amount of days before the current day)
	 DaysAhead = 0  (end at the last day of the month)
	 DaysAhead > 0  (end a specific amount of days ahead of the current day)
 Horizontal_Days_InThisMonth (a horizontal layout of days in the month)
	 DaysBehind = 0  (start at the first day of the month)
	 DaysBehind > 0  (start a specific amount of days before the current day)
	 DaysAhead = 0  (end at the last day of the month)
	 DaysAhead > 0  (end a specific amount of days ahead of the current day)
	 OmitToday = 0  (do not remove today)
	 OmitToday = 1  (do remove today)
 Horizontal_Weekdays_Today (a horizontal layout of the current weekday)
	 DaysBehind = 0  (start at the first day of the month)
	 DaysBehind > 0  (start a specific amount of days before the current day)
	 DaysAhead = 0  (end at the last day of the month)
	 DaysAhead > 0  (end a specific amount of days ahead of the current day)
	 Abbreviate = 0  (do not abbreviate)
	 Abbreviate = 1  (do abbreviate)
	 Length = 0  (full weekday name, or full abbreviated name)
	 Length = 1  (first letter only)
	 Length = 2  (first two letters)
	 Length = 3  (first three letters)
 Horizontal_Weekdays_InThisMonth (a horizontal layout of weekdays in the month)
	 same parameters as Horizontal_Weekdays_Today 
 Horizontal_UserDefined_Today (a horizontal layout with a user defined indicator style char for today)
	 IndicatorStr  (any indicator you want that's between 1-4 characters long)
 Horizontal_UserDefined_InThisMonth (a horizontal layout with a user defined indicator style char for all days in the month)
	 IndicatorStr  (any indicator you want that's between 1-4 characters long)

These vertical functions have the same parameters as the horizontal functions:
 Vertical_Days_Today (a vertical layout of the current day)
 Vertical_Days_InThisMonth (a vertical layout of days in the month)
 Vertical_Weekdays_Today (a vertical layout of the current weekday)
 Vertical_Weekdays_InThisMonth (a vertical layout of weekdays in the month)
 Vertical_UserDefined_Today (a horizontal layout with a user defined indicator style char for today)
 Vertical_UserDefined_InThisMonth (a horizontal layout with a user defined indicator style char for all days in the month)






__________________________________________________________
http://www.geocities.com/samurize@swbell.net/samurize.html
uziq@hotmail.com
